*----------------------------------------------------------------------	*
* The Political Geography of the Gender Gap							   	*
* Journal of Politics, 2023                                           	*
* Dawn Langan Teele, Johns Hopkins University                         	*
* correspondence: teele.academic@gmail.com                            	*
* Last modificaiton: 01/13/2023                                       	*
* Version of Stata SE 14.2                                            	*
* Operating System Mac OS 12.3                                        	*	 
* ---------------------------------------------------------------------	*
* Additional data and programs needed                                 	*
* 1.) Swedish National Data Service Study 0204. Accessed by us online 	*
*     https://snd.gu.se/en/catalogue/study/snd0204                    	*
*     note: many errors in this data fixed in errorfix.do             	* 
* 2.) grcl1eg															*
* 3.) tufte scheme														*
* 4.) lgraph															*
* ---------------------------------------------------------------------	*
* List of files contained in replicaiton code                         	*
* 	"0. Read Me.do"                                                   	*
*	"1. prep_1911-1941.do"                                            	*
*      	> Creates "Sweden 1911-1944_panel.dta"                        	*
*		> calls on "6. Stockholm.xlsx" user downloaded SND Database " 	*
*		> names variables and cleans new variables.                   	*
*		> calls on errorfix.do                                        	*
*		> Merges in data on Stockholm's wards                         	*
*		> reshapes the raw data into a panel.                         	*
*	"2. errorfix.do"                    								*	
* 		> Provides some code to locate errors and fixes nearly 			*
*		1000 mistakes in the original SND data. 						*
* 	"3. Fig 1.do" 														*
*		> Executes commands for Figure 1 								*
*		> produces summary statistics that are cited in text. 			*
*	"4. Fig 2.do" 														*
*		> Executes commands for Figure 2								*
*	"5. Fig 3.do" 														*
*		> Executes the main counterfactual estimates.					* 
*		> creates "simulation.dta"										*
*		> Executes command for Figure 3									*
*	"6. Fig 4.do" 														*
*		> Executes command for Figure 4 and Table 2						*
*	"7. appendix.do" 													*
*	./raw/"Stockhomlm.xlsx" 											*	
*		> File invoked by "1. prep_1911-1941.do"						*
*		> Open spreadsheet for citations to original data.				*
*	"8. Codebook.pdf"													*
* ---------------------------------------------------------------------	*


*-------------------------------*
* 1.) Choose working directory  *
*-------------------------------*
* Define a working directory
* User should choose the directory where the folder was unzipped
* User should create sub-directory "images" "images/appendix" and 
* "raw"
cd "YOUR DIRECTORY HERE 

*-------------*
* 2.) Build	  *
*-------------*

do "1. prep.do"

*------------------------------------*
* 3.) Main Paper Figures and Tables  *
*------------------------------------*

do "3. Fig 1.do"
do "4. Fig 2.do" 
do "5. Fig 3.do" 
do "6. Fig 4.do" 

*-----------------------*
* 4.) Appendix figures  *
*-----------------------*

do "7. appendix.do" 
